package com.xxxx.yebserver.controller;


import com.xxxx.yebserver.common.R;
import com.xxxx.yebserver.common.page.PageUtils;
import com.xxxx.yebserver.service.EmployeeService;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.Map;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author cxq
 * @since 2021-06-15
 */
@RestController
@RequestMapping("/employee/basic")
public class EmployeeController {
    @Autowired
    EmployeeService employeeService;

    @ApiOperation(value = "获取所有的员工")
    @GetMapping("/")
    public R getEmployee(@RequestParam Map<String,Object> map){
        PageUtils page = employeeService.getEmployee(map);
        return R.ok().data(page);
    }
}

